Compile time meta-object protocol systems and methods

ABSTRACT

The subject invention pertains to a compilation system and meta-object protocol to facilitate interaction with objects of various types including but not limited to XML documents. More specifically, a delineator or dot operator can be extended to hide idiosyncratic details of interacting with objects. Code details can be generated by a compiler behind the scenes. This enables a programmer to achieve the same results while writing much simpler and intuitive code.

COPYRIGHT NOTICE

A portion of the disclosure of this patent document contains material,which is subject to copyright protection. The copyright owner has noobjection to the facsimile reproduction by anyone of the patent documentor patent disclosure, as it appears in the Patent and Trademark Officepatent file or records, but otherwise reserves all copyright rightswhatsoever.

TECHNICAL FIELD

The subject invention relates generally to computers and moreparticularly toward compilers and computer programming languages.

BACKGROUND

Programming languages continue to evolve to facilitate specification byprogrammers as well as efficient execution. In the early days ofcomputer languages, low-level machine code was prevalent. With machinecode, a computer program or instructions comprising a computer programwere written with machine languages or assembly languages and executedby the hardware (e.g., microprocessor). These languages provided a meansto efficiently control computing hardware, but were very difficult forprogrammers to understand and develop sophisticated logic. Subsequently,languages were introduced that provided various layers of abstraction.Accordingly, programmers could write programs at a higher level with ahigher-level source language, which could then be converted via acompiler or interpreter to the lower level machine language understoodby the hardware. Further advances in programming have providedadditional layers of abstraction to allow more advanced programminglogic to be specified much quicker then ever before. However, theseadvances do not come without a processing cost.

Compilers and/or interpreters bear the burden of translating high-levellogic into executable machine code. In general, a compilers and/orinterpreters are components that receive a program specified in a sourceprogramming language (e.g., C, C#, Visual Basic, Java . . . ) and covertthe logic provided thereby to machine language that is executable by ahardware device. However, the conversion need not be done verbatim. Infact, conventional compilers and/or interpreters analyze the source codeand generate very efficient code. For example, programmers write codethat sets forth a logical flow of operations that is intuitive and easyfor humans to understand, but is often inefficient for a computer toexecute. Compilers and/or interpreters can identify inefficiencies andimprove program performance at the hardware level by eliminatingunnecessary operations and/or rearranging the execution of instructionsbut still achieving the intended results. In this manner, programmerscan create robust and efficient software programs.

Extensible Markup Language (XML) has become quite a popular programminglanguage. XML is a markup language that provides a format for describingstructured data. Similar to HTML (Hyper Text Markup Language), XML is atag-based language that defines a strict tree structure or hierarchy.XML is a derivative of Standard Generalized Markup Language (SGML) thatprovides a format for describing and exchanging structured data in anopen text based format. Unlike HTML, which is a display-orientedlanguage, XML is a general-purpose language for representing structureddata without including information pertaining to how it is to bedisplayed. XML consists of elements, and attributes, among other things.

XML elements are structural constructs that consist of a start tag, anend or close tag, and the information or content that is containedbetween the tags. A start tag is formatted as “<tagname>” and an end tagis formatted as “</tagname>.” In an XML document, start and end tags canbe nested within other start and end tags. All elements that occurwithin a particular element must have their start and end tags occurbefore the end tag of that particular element. This defines a stricttree-like hierarchical structure. Each element forms a node in thistree, and potentially has child or branch nodes. The child nodesrepresent any XML elements that occur between the start and end tags ofthe parent node.

XML can accommodate an infinite number of database schemas. Within eachschema, a dictionary of element names is defined. The dictionary ofelement names defined by a schema is referred to as a namespace. Withinan XML document, element names are qualified by namespace identifiers.When qualified by a namespace identifier, a tag name appears in the form“[namespace]:[tagname]”. This model enables the same element name toappear in multiple schemas, or namespaces, and for instances of theseduplicate element names to appear in the same XML document withoutcolliding. Start tags can declare an arbitrary number of attributes,which declare property values associated with the element beingdeclared. Attributes are declared within the start tag using the form“<[tagname] [attribute1],[attribute2] . . . , [attributeN]>”, where anattribute₁ through attribute_(N) are declarations of an arbitrary numberof tag attributes. Each attribute declaration is of the form“[attributeName]=[attributeValue]” where each attribute is identified bya unique name followed by an “=” character, followed by the value of theattribute.

To facilitate such interaction with XML documents via high-level objectoriented programming languages, for instance, an XML Application ProgramInterface (API) can be employed. An XML API provides a set of rules or aprotocol to enable communication between an XML document and clientapplication. There are a number of different types. For example, thereare push APIs like SAX (Simple API for XML) where an API parserserializes a document and pushes the parsed data to a clientapplication. Another type of XML API is a tree-based API such as DOM(Document Object Model). With this type of API, an XML document isparsed and an object model comprising a tree or hierarchy of nodes forXML elements, attributes, etc is constructed and housed in memory.Methods can then be directed at the object model for retrieving,modifying and adding data to the document. There are also query-basedAPIs. With these, XML documents are searched and data is returned inaccordance with the search utilizing XPath (XML Path Language), forexample. XPath is a language that locates and addresses information inan XML document by navigating through its elements and attributes. XPathqueries are specified in terms of paths and expressions. In essence,XPath is incorporated into a programming application (e.g., C#, Java,Visual Basic . . . ) just like SQL (Structured Query Language). A usercan query a database from within an application by specifying SQLqueries. A database management system will receive these queries andreturn the results. Likewise, an XPath query can be specified within anapplication, and an XPath engine will process the query against an XMLdocument and return requested information.

Conventional APIs for processing XML are notoriously difficult to use.They provide a document object model over data in the XML documentutilizing types such as XmlNode and XPathNavigator. To navigate atypical XML document object model, a user has to deal with severalclasses whose interaction is often complex and counter intuitive. Forexample, the System.Xml.XPath namespace contains a variety of classesthat allow users to load an XML document, to navigate toward specificnodes using XPath queries represented by plain strings and thenimperatively iterate through these nodes to pick out values that a useris ultimately interested in retrieving. The iterator iterates over acollection of navigators each navigator has the Select( ) method thatreturns an iterator over the new set of navigators that points to thenodes that were selected.

SUMMARY

The following presents a simplified summary of the invention in order toprovide a basic understanding of some aspects of the invention. Thissummary is not an extensive overview of the invention. It is notintended to identify key/critical elements of the invention or todelineate the scope of the invention. Its sole purpose is to presentsome concepts of the invention in a simplified form as a prelude to themore detailed description that is presented later.

Briefly described the subject invention concerns systems and methods tofacilitate simple and intuitive programming. More specifically,compilation systems and methods are provided that support overloading adelimiter operator such as the dot operator to hide programmatic detailsfrom programmers. These details can be determined and automaticallygenerated and injected under the covers by a compiler. According to aspecific aspect of the subject invention, access to XML documents ismade easier by the systems and methods provided herein. However, thesubject invention is not so limited.

According to an aspect of the subject invention, a compilation system isprovided comprising a receiver component for receiving a delimitedprogrammatic expression, a type detection component to determine a typeassociated with the expression and a generation component that generatesa translated expression. The translated expression can comprise at leasta portion that includes a generic method call initially not bound to aspecific implementation. For example, if a programmatic expression isdelimited by a dot operator a generic method “Dot( )” can be generated.Later a specific implementation can be bound to the generic method, forexample based on the expression type. Hence, based on the type of theobject or thing that is to be accessed, there is a special protocol ormeta-object protocol that is executed that provides some additional workbehind the scenes that is invisible to a programmer.

According to an aspect of the invention, a programmer need only specifyan expression or qualified identifier comprising related elementsdelimited by some object or character. The subject systems and methodscan automatically generate the proper code, for example based on thetype of the object being accessed. Therefore, access to XML documentscan be specified the same way access to class members is specified intypical object-oriented programming languages. Upon compilation, theappropriate protocols will be executed to facilitate the specified dataaccess.

To the accomplishment of the foregoing and related ends, certainillustrative aspects of the invention are described herein in connectionwith the following description and the annexed drawings. These aspectsare indicative of various ways in which the invention may be practiced,all of which are intended to be covered by the present invention. Otheradvantages and novel features of the invention may become apparent fromthe following detailed description of the invention when considered inconjunction with the drawings.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a block diagram of a compilation system in accordance with anaspect of the subject invention.

FIG. 2 is a block diagram of a compilation system in accordance with anaspect of the subject invention.

FIG. 3 is a block diagram of a compilation system in accordance with anaspect of the subject invention.

FIG. 4 is a block diagram of a compilation system in accordance with anaspect of the subject invention.

FIG. 5 is a block diagram of a compilation interaction system inaccordance with an aspect of the subject invention.

FIG. 6 is a flow chart diagram of a compilation methodology inaccordance with an aspect of the subject invention.

FIG. 7 is a flow chart diagram of a compilation methodology inaccordance with an aspect of the subject invention.

FIG. 8 is a flow chart diagram of a compilation methodology inaccordance with an aspect of the subject invention.

FIG. 9 is a flow chart diagram of a compilation methodology inaccordance with an aspect of the subject invention.

FIG. 10 is a schematic block diagram of a sample compiler environmentwithin which aspects of the invention can be incorporated.

FIG. 11 is a schematic block diagram illustrating a suitable operatingenvironment in accordance with an aspect of the subject invention.

FIG. 12 is a schematic block diagram of a sample-computing environmentwith which the subject invention can interact.

DETAILED DESCRIPTION

The present invention is now described with reference to the annexeddrawings, wherein like numerals refer to like or corresponding elementsthroughout. It should be understood, however, that the drawings anddetailed description thereto are not intended to limit the invention tothe particular form disclosed. Rather, the intention is to cover allmodifications, equivalents, and alternatives falling within the spiritand scope of the present invention.

As used in this application, the terms “component” and “system” and thelike are intended to refer to a computer-related entity, eitherhardware, a combination of hardware and software, software, or softwarein execution. For example, a component may be, but is not limited tobeing, a process running on a processor, a processor, an object, aninstance, an executable, a thread of execution, a program, and/or acomputer. By way of illustration, both an application running on acomputer and the computer can be a component. One or more components mayreside within a process and/or thread of execution and a component maybe localized on one computer and/or distributed between two or morecomputers.

The word “exemplary” is used herein to mean serving as an example,instance, or illustration. Any aspect or design described herein as“exemplary” is not necessarily to be construed as preferred oradvantageous over other aspects or designs.

Artificial intelligence based systems (e.g., explicitly and/orimplicitly trained classifiers) can be employed in connection withperforming inference and/or probabilistic determinations and/orstatistical-based determinations as in accordance with one or moreaspects of the subject invention as described hereinafter. As usedherein, the term “inference” refers generally to the process ofreasoning about or inferring states of the system, environment, and/oruser from a set of observations as captured via events and/or data.Inference can be employed to identify a specific context or action, orcan generate a probability distribution over states, for example. Theinference can be probabilistic—that is, the computation of a probabilitydistribution over states of interest based on a consideration of dataand events. Inference can also refer to techniques employed forcomposing higher-level events from a set of events and/or data. Suchinference results in the construction of new events or actions from aset of observed events and/or stored event data, whether or not theevents are correlated in close temporal proximity, and whether theevents and data come from one or several event and data sources. Variousclassification schemes and/or systems (e.g., support vector machines,neural networks, expert systems, Bayesian belief networks, fuzzy logic,data fusion engines . . . ) can be employed in connection withperforming automatic and/or inferred action in connection with thesubject invention.

Furthermore, the subject invention may be implemented as a method,apparatus, or article of manufacture using standard programming and/orengineering techniques to produce software, firmware, hardware, or anycombination thereof to control a computer to implement the disclosedinvention. The term “article of manufacture” as used herein is intendedto encompass a computer program accessible from any computer-readabledevice, carrier, or media. For example, computer readable media caninclude but are not limited to magnetic storage devices (e.g., harddisk, floppy disk, magnetic strips . . . ), optical disks (e.g., compactdisk (CD), digital versatile disk (DVD) . . . ), smart cards, and flashmemory devices (e.g., card, stick, key drive . . . ). Additionally itshould be appreciated that a carrier wave can be employed to carrycomputer-readable electronic data such as those used in transmitting andreceiving electronic mail or in accessing a network such as the Internetor a local area network (LAN). Of course, those skilled in the art willrecognize many modifications may be made to this configuration withoutdeparting from the scope or spirit of the subject invention.

Turning initially to FIG. 1, a compilation system 100 is illustrated inaccordance with an aspect of the subject invention. Compilation system100 can include receiver component 110, type detection component 120,and generation component 130. Receiver component 110 can receive and/orretrieve expressions or qualified identifiers. According to an aspect ofthe invention, such expressions can be delimited programmaticexpressions. In particular, the programmatic expression can be a memberaccess expression of the formMember-Access-Expression::=Receiver-Expression DelimiterMessage-Identifier. For example, such expressions can correspond to X.Y.X!Y, X.@Y, X.Y.Z, and the like, where there are at least two elements(e.g., X, Y . . . ) separated by a delimiter (e.g., dot (.), series ofdots ( . . . ), exclamation point (!), pound sign (#) . . . ).Furthermore, it should be appreciated that the message-identifier cantake on any of a myriad of forms including but not limited to (a)[identifier], pr, (b) @attribute, (c) @[An Attribute], (d) prefix:name,(e) @prefix:name, (f) [prefix]:[name], or any combination thereof.Receiver component 110 is communicatively coupled to type detectioncomponent 120 and generation component 130. Type detection component 120can determine the type associated with an element in the receivedprogrammatic expression. In particular, the type detection component 120can determine type from the element preceding the delimiter or the firstelement. Such an element can correspond to an object or class definingthe object. The type determination can be made by analyzing the declaredelement and its return type and/or checking a type declaration precedingthe specified element as is often specified. The determine type can thenbe communicated to the generation component 130 from the type detectioncomponent 120. Accordingly, the generation component 130 can receive,among other things, type information as well as the programmaticelements themselves.

Generation component 130 can generate or produce translated expressions.Programmatic expressions are often simplified or abbreviated tofacilitate straightforward and intuitive programming. Behind the scenes,a compiler or interpreter component(s) can translate the expression intoits proper format. In essence, an abstraction of the actualimplementation is provided for specification by programmers to increaseprogramming efficiency and eloquence. Generation component 130 providessimilar functionality here. In the simple instance where there are twoelements separated by a delimiter such as a dot. The analysis componentcan analyze the second element relative to the first. A determinationcan be made as to whether the second element represents or is a memberof the type of the first element. For example, a determination can bemade concerning whether the second element is a property or field of thefirst element type. If it is, then a translated expression can begenerated that incorporates standard or normal methods for the delimitersuch as get and set methods. For example, if an expression is C.age,where C is of type Customer and age is a property of the type or classCustomer, the translated expression C.get_age( ) can be generated.However, if the second element is not a member or direct member of thetype of the first element, then the generation component can generate ageneric method call as the translated expression. For example, thegeneric method call can for an expression X.Y could be X.Dot(“Y”). Thisgeneric method call does not specify a particular translation. Inaccordance, with an aspect of the invention, the generic method callincreases the flexibility associated with the expression, as it is notbound to any particular implementation initially. The generic methodimplementation later can be tied to an implementation based on the typeof the first element, for instance. Stated differently, the delimiteroperator, or in the example above, the dot operator can be overloaded tohide an interpretive layer or provide an additional layer ofabstraction.

FIG. 2 depicts a compilation system 200 in accordance with an aspect ofthe subject invention. System 200 includes type component 120, bindingcomponent 210 and generation component 130. Type detection componentdetermines a type associated with a received expression. In particular,in a member-access expression, the type detection component 120 canascertain the type of the first element or receiver expression.Generation component 130 can generate a translated expression from aninitially provided expression. For example, the generation component 130can receive a simplified expression and based on that expression'selements (e.g., receiver expression, delimiter, message identifier) cangenerate an expanded translated expression. Binding component 210 bindsthe code or expression generated by generation component 130 to aspecific implementation or type. According to one aspect of theinvention, the bind component 210 can correspond to the type identifiedby type detection component 120. A type or data type defines aparticular type, kind, or classification of data.

It should be appreciated that compilation system 200 can correspond toor implement a compile time meta-object protocol. For instance,generation component 120 can initially produce a generic expression ormethod call based on the received expression. The generic method callcan be generated by a compiler initially upon analyzing a receivedexpression. As provided supra, the translated expression can include thegeneric expression such as X.Dot(“Y”), for example. The bindingcomponent 220 binds or ties the generic expression to a particularimplementation. In particular, the binding component 220 can bind thegeneric expression or more specifically the generic method call to thetype provided by the type detection component 120. For example, if thetype is an XML object type the generation component would be bound tospecify XML code that replaces the generic method in the translatedexpression. For example, X.Dot(“Y”) could be replaced withX.Current.SelectChildren(“Y”). In other words, the generation component130 can produce a translated expression in accordance with a typespecific implementation of the generic method call, in this example theDot method. This indirection or generality provided by the system of thesubject invention enables compiler extensibility. For every differentdata form or type, the compilation thereof can be different rather thanhard coded or tied to a specific implementation.

FIG. 3 depicts another compilation system 300 in accordance with anaspect of the subject invention. Similar to system 100 of FIG. 1, system300 includes a receiver component 110, a type detection component 120,and a generation component 130. The receiver component 110 receivesand/or retrieves a delimited programmatic expression, a qualifiedidentifier, or a member access expression. The type detection component120 determines the type of an element in the expression such as thefirst element. The generation component 130 receives a type from thetype detection component 120 and expression elements (e.g., firstelement, delimiter, second element . . . ). System 300 also includes anambiguity component 310. Ambiguity component 310 can be utilized inconjunction with the generation component 130 to facilitate resolvingambiguities regarding the transformed expression to be generated. Asmentioned previously, the generation component 130 is operable todetermine whether the second element in an expression is a member (e.g.,field, property) of the type of the first expression, for instance. Ifthe second element is a member of the type of the first, a specifictranslation expression was generated by generation component 110, ratherthan a generic method call. This corresponds to generation of standardor normal member access code. However, a programmer may want the genericmethod call to be generated by the compiler even when the second elementis a member of the type of the first. Ambiguity component 310 can be ofassistance in such a situation. For example, ambiguity component 310 canstore or access a default rule for dealing with an ambiguous situationand provide direction to the generation component 130. In accordance,with another aspect of the invention the ambiguity component can analyzethe delimiter or delimiters associated with the expression to determinehow to resolve the situation. In this manner, programmers are empoweredto specify how they would like the expression to be compiled. Forexample, instead of writing X.Y, the programmer could write X!Y or X.!Yto indicate that the compiler should generate a generic method call evenif the second element is a member of the type of the first. Hence,ambiguity component 310 can retrieve the delimiter(s), utilize them todetermine how a translated expression should be generated, and providethat information to the generation component 130. In other words, theambiguity resolution component determination can be influenced by anexpression delimiter such that either the ambiguity component defaultsto normal member access and can be overridden by a particular delimiterto produce special member access code or defaults to special memberaccess code which may be overridden by the presence of a particulardelimiter to produce normal member access code.

FIG. 4 presents a compilation system 400 in accordance with an aspect ofthe subject invention. Similar to systems 100 (FIG. 1) and 300 (FIG. 3),system 400 includes receiver component 110, type detection component 120and generation component 130. Again, receiver component 110 receives adelimited programmatic expression or qualified identifier. Typedetection component 120 is operable to determine the type of the firstelement in an expression. Generation component 130 receives the typeinformation as well as the expression elements themselves and generatesa translated expression. If the second element is not a member of thetype of the first class, then the generation component 130 can generatea generic method call. However, this need not be the same generic methodcall. Generation component 130 includes or can be communicativelycoupled to an element analysis component 132. Element analysis component132 can analyze elements in a programmatic expression. In particular, itcan scrutinize an element following a delimiter to determine its type orkind of data. A generic method call can then be generated that is morespecifically tailored to the element following the delimiter. Forexample, the element analysis component 132 can determine that thesecond element is an attribute and communicate this information to thegeneration component 130. The generation component can then generate aunique generic method call. For example, rather than generatingX.Dot(“Y”), the generator component 130 could generateX.DotAttribute(“Y”). Similarly, at a later point the generic method canbe bound to a specific implementation particularly for DotAttribute( )in the above example.

Turning to FIG. 5, a compilation interaction system 500 is illustratedin accordance with an aspect of the subject invention. System 500includes a type component 510 and a compilation component 520. Typecomponent 510 and compilation component 520 are communicatively coupled.For example, the components may communicate via data packets transmittedthere between. A type component 510 defines an object and can include,among other things, one or more methods and associated implementations.Accordingly, the type component 510 can correspond to a programmaticclass as specified in an object oriented programming language. Thecompilation component 520, inter alia, can generate a generic methodcall associated with translating all or part of an expression beingcompiled. For example, the generic method call can be the dot aspreviously discussed (e.g., X.Dot(“Y”)). The generic method call is veryflexible, as the implementation of that method is not bound to anythingspecific. The type component 510 can provide a specific implementationof the generic method for its particular type and objects of that type.For example, it can include a Dot method implementation. In order toobtain the implementation for its generic method and generate atranslated expression, the compilation component 520 must first locate aspecific type component 510 and subsequently negotiate therewith. Inessence, the compilation component 520 communicates and informs the typecomponent 510 that it has a particular generic method and possibly somearguments that are associated with the type component 520. The typecomponent 520 can then inform the compilation component how to implementthe method. In a conventional, language translation system theimplementation is hard coded. Therefore, if a user specifies C.age, itis always translated to C.get_age( ), for example. This is not veryflexible or extensible. Here, the compilation component 520 calls ageneric method and the type component 510 provides some complex logicthat the compiler does not know about and yet it still the compilationcomponent 520 produces the desired behavior.

As will be appreciated by those artisans of ordinary skill in thisfield, various portions of the disclosed system may include or consistof artificial intelligence- or knowledge based components. For example,the generation component 130 of FIGS. 1, 3, and 4, may use a neuralnetwork to facilitate generation of translation expressions.Furthermore, the subject invention can employ classifiers that areexplicitly trained, for example, using generic training data, as well asimplicitly trained, such as by observing user behavior or receivingextrinsic information. For example, SVM's are configured using alearning or training phase within a classifier constructor and featureselection module. Thus, the classifier(s) can be used to automaticallyperform a number of functions.

According to a particular aspect of the invention, such a system asdescribed above can be utilized to facilitate access to XML data anddocuments. Existing application programming interfaces (APIs) forprocessing XML are notoriously difficult to use. They provide a documentobject model over the data in the XML document using types such asXmlNode and XPathNavigator. To navigate a typical XML document objectmodel, a user has to deal with several classes whose interaction isoften complex and counter intuitive. For instance, the System.Xml.XPathnamespace contains a variety of classes that allow users to load an XMLdocument, to navigate towards specific nodes using XPath queriesrepresented by plain strings and then imperatively iterate through thesenodes to pick out the values with which a user is ultimately interested.The iterator iterates over a collection of navigators that points to thenodes that were selected.

Consider the complexity in the following example where two documentsthat contain books are joined based on their title and the outputincludes a list of the books and their prices in each document. A usercan then navigate the list by creating navigator objects on the documentand the calling the Select( . . . ) method to create iterators that inturn contain navigators on the selected nodes, etc.

static void UseXPathDocument  (string reviewsLocation, stringbibLocation, XmlTextWriter xtw) {  XPathDocument bib = newXPathDocument(bibLocation);  XPathDocument reviews = newXPathDocument(reviewsLocation); xtw.WriteStartElement(“books-with-prices”);  XPathNodeIterator books =bib.CreateNavigator( ).Select(“/bib/book”);  while (books.MoveNext( )) {  XPathNodeIterator entries =     reviews.CreateNavigator().Select(“/reviews/entry”);   XPathNodeIterator bookTitleItr =   books.Current.SelectChildren(“title”,“ ”); bookTitleItr.MoveNext( );  XPathNodeIterator bookPriceItr =   books.Current.SelectChildren(“price”,“ ”); bookPriceItr.MoveNext( );  while(entries.MoveNext( )) {    XPathNodeIterator entryTitleItr =    entries.Current.SelectChildren(“title”,“ ”); entryTitleItr.MoveNext();    XPathNodeIterator entryPriceItr =    entries.Current.SelectChildren(“price”,“ ”);    entryPriceItr.MoveNext( );     if (entryTitleItr.Current.Value ==bookTitleItr.Current.Value) {      WriteBook(xtw,bookTitleItr.Current,entryPriceItr.Current,        bookPriceItr.Current);     }    }   } xtw.WriteEndElement( );  }

The developer writing this code needs to be intimately familiar with theinteraction between the various classes as provide above. In addition,the developer needs to understand the subtle semantics of the XPathquery language, write many imperative statements to explicitly navigatethrough a tree hierarchy, and retrieve the appropriate values. Furtheryet, the developer needs to understand the additional layer ofinterpretation of using various methods such as Select( ) andSelectChildren( ). In contrast, to navigate standard object models orclasses programmers can directly use the more traditional “object.name”operator to access “children” of objects rather than callingobject.SelectChildren(“name”).

One way to allow for a more direct navigation of XML documents usingordinary member access is to deserialize an XML document into acorresponding object graph where roughly each XML element is representedby a class that contains field or property members of each child elementof that particular element. However, there are several downsides to thisapproach. First of all, this requires that the schema of the document inquestion be known at program construction time, which is often not thecase. Even when the document schema is available, the XML and objectschema languages differ very significantly, and in many cases it is notpossible to create a faithful mapping between XML schema and a set ofobject oriented classes. Furthermore, deserialization invariably leadsto loss of fidelity of the XML document; meaning that round tripping adocument by first deserializing it into an object and then serializingback into XML does not result with which you started.

According to an aspect of the subject invention, a delimiter operatorsuch as the dot operator can be overloaded to hide the interpretivelayer of having to call Select( ) and SelectChildren( ), for example,allowing a user to directly access members on a receiver of type XML. Acompiler can generate the required code to the appropriate memberselection methods under the covers. This provides the same results asabove by writing much simpler and intuitive code. Consider the followingcode snippet the same functionality as the previous code snippet. Thenew code is bold faced.

static void UseDynamicXPathDocument(string reviewsLocation, stringbibLocation, XmlTextWriter xtw) {  DynamicXPathDocument bibDoc = new DynamicXPathDocument(bibLocation);  DynamicXPathDocument reviewsDoc =new DynamicXPathDocument(reviewsLocation); xtw.WriteStartElement(“books-with-prices”);  foreach(DynamicXPathNavigator book in bibDoc.bib.book)  foreach(DynamicXPathNavigator entry in reviewsDoc.reviews.entry)    if((string)book.title == (string)entry.title)    WriteBook(xtw,book.title,entry.price, book.price);  xtw.WriteEndElement( ); }

In this example, once the DynamicXPathDocument is created the top levelelements now seem to appear as regular properties of the bibDoc object.Selecting bibDoc.book.bib returns a collection of DynamicXpathNavigatorobjects that point to applicable child nodes or an attribute with thatproperty name. This collection itself can have a property thatrepresents the child nodes of each navigator in that collection. Oncethis collection is cast to a string (implicitly or explicitly) thecurrent navigator value is returned.

The conventional compilation of the dot (“.”) operator is employed tosearch in the receiver type (left side of the dot) for the member thatmatches the specified member (right side of dot). However, in accordancewith an aspect of the invention this technique is modified to addbehavior for when this conventional search fails. However, a variationof this scheme can be to always insert the non-standard behavior.

If the XML API class does not have a direct member that matches themember (after the dot, a compiler system can insert instead a genericmethod call to the “Dot” or alternatively “DotAttribute.” These methodsreturn the applicable XML nodes by calling applicable methods so thatthe expressions that use the dot operator are composable. To illustratesuch composability, consider the following code fragment:

DynamicXPathDocument bibDoc=new DynamicXPathDocument(bibLocation);foreach (DynamicXPathNavigator book in bibDoc.bib.book){

Here the bibDoc does not have a member called bib thus a generic Dotmethod can be inserted that specifies bib as an argument as follows:

foreach (DynamicXPathNavigator book in bibDoc.Dot(“bib”).book){

The return type for the Dot method is DynamicXPathNavigator onDynamicXPath Document and such type does not have a book member. Hence,another call can be inserted to the Dot method. As a result, theexpression bibDoc.bib.book is translated into the expressionbibDoc.Dot(“bib”).Dot(“book”) as shown in the following code snippet:Foreach (DynamicXPathNavigator book in bibDoc.Dot(“bib”).Dot(“book”))

It should also be appreciated that programmers as well as generationcomponent 130 (FIGS. 1, 3 and 4) and compilation component 520 (FIG. 5)may have to compensate for particular identifiers differently. Asdiscussed previously, an expression like books.price can be specified.However, identifiers need not be specified as single word strings. Forexample, an identifier could correspond to an XML tag<large-print-book>. Uses of dashes or minus signs are legal in XML.However, if a user specified books.large-print-books this could beproblematic. For example, a language such as C# could interpret thisarithmetically as books.large minus print minus books, which wouldlikely generate an error. Accordingly, the subject inventioncontemplates use of additional delimiters to eliminate such confusion,for example books. [large-print-books], books.<large-print-books> orbooks.large\-print\-books could be employed.

Furthermore, various delimiters can map to various XPath axes (e.g.,child, descendant, ancestor, parent, attribute, namespace . . . ). Forinstance, a series of two dots ( . . . ) can map to descendents, while aseries of three dots ( . . . ) could map to ancestors, and the like.

In view of the exemplary systems described supra, methodologies that maybe implemented in accordance with the present invention will be betterappreciated with reference to the flow charts of FIGS. 6-9. While forpurposes of simplicity of explanation, the methodologies are shown anddescribed as a series of blocks, it is to be understood and appreciatedthat the present invention is not limited by the order of the blocks, assome blocks may, in accordance with the present invention, occur indifferent orders and/or concurrently with other blocks from what isdepicted and described herein. Moreover, not all illustrated blocks maybe required to implement the methodology in accordance with the presentinvention.

Additionally, it should be further appreciated that the methodologiesdisclosed hereinafter and throughout this specification are capable ofbeing stored on an article of manufacture to facilitate transporting andtransferring such methodologies to computers. The term article ofmanufacture, as used herein, is intended to encompass a computer programaccessible from any computer-readable device, carrier, or media.

Turning to FIG. 6, a compilation method 600 is illustrated in accordancewith an aspect of the subject invention. At 610, a delimited expression,qualified identifier, or member access expression is received. Forexample, the expression could be X.Y. In such an example, X representsan object and Y represents an associated element or element associatedwith the object in some manner. At 620, a translated expression isgenerated. Initially, the translated expression may include a genericmethod call not bound to any particular implementation. The genericmethod call specifies that there is some relationship between the objectand the associated element. By way of example, the produced genericmethod call can correspond to a dot method where the associated elementis an argument thereto such as Dot(“Y”). Thus, the translated expressioncorresponds to X.Dot(“Y”) and the generic dot method can be bound to aparticular implementation based at least in part upon the type of theobject X, at a later time (e.g., compile time).

FIG. 7 a compilation methodology 700 is depicted in accordance with anaspect of the subject invention. At 710, a delimited programmaticexpression or qualified identifier is received. As previously described,the expression can consist of at least two elements separated by one ormore delimiters. The first element can correspond to an object while theremaining elements can be associated with the first element in somemanner. The expression can be a member access expression of the formMember-Access-Expression::=Receiver-Expression DelimiterMessage-Identifier. Accordingly, an exemplary generic expression couldbe X.Y. At 720, the type of the object, specified by the first elementleft of the delimiter, is determined. At 730, a determination is made asto whether associated element to the right of the delimiter is a memberof the type of the object or element to the left of the delimiter. Forexample, the right element could be a member such as a property or fieldof the type of the first element. If the right element is a member ofthe type of the left element, then at 740 a standard direct get methodis specified for the element to the right of the delimiter, such asget_Y( ). Accordingly, the entire translated expression would readX.get_Y( ) rather than the initially received X.Y. If, however, theright element is not a member of the type of the left element, then at750 a generic method call is specified for the right element. In thesubject example, such a method could correspond to Dot(“Y”) where Y isnow an argument to the generic method. The entire translated expressioncorresponds to X.Dot(“Y”). Here, the generic method is not tied to anyparticular implementation, as is the case where the right element is amember of the type of the left element. Accordingly, this compilationmethodology 700 expands the conventional scenario of directly tying theoperation between two elements to a specific implementation, whichprovides for flexibility and extensibility while still supporting thestandard case. Stated differently, methodology 700 can correspond to ameta-object protocol that overloads the functionality of a delimitersuch as the dot operator.

Turning to FIG. 8, a compilation methodology 800 is illustrated inaccordance with an aspect of the subject invention. Methodology 800begins with similar actions as methodology 700 of FIG. 7. At 810, adelimited programmatic expression is received. The programmaticexpression can include at least two elements separated by at least onedelimiter. The first element to the left of the delimiter can correspondto an object while the element(s) to the left of the delimiter can beelements associated with the object At 820, the type of the element tothe left of the delimiter is determined. At 830, a determination is madeas to whether the element to the right of the delimiter is a member ofthe type of the element to the left of the delimiter. For example, anitem can be a member of a type if it corresponds to a field or property,among other things, of the type or class implementing the type. If theelement is a member of the type, than at 840 a direct getter method isspecified for the expression. For example, the expression can betransformed from X.Y to X.get_Y( ). This would be a standardimplementation for the dot operator. However, if the element is not amember of the type of the element to the left of the delimiter, then at850 a determination is made as to whether the right element is anattribute. This can be determine, for example, by identifying whetherthe element or the delimiter includes a symbol such as “@.” If theelement to the right of the delimiter is an attribute than a genericmethod can be generated for the element, which indicates that it is anattribute such as DotAttribute(“Y”). Accordingly, an original expressionof X.Y can be transformed to X.DotAttribute(“Y”), for example. If at 850it is determined that the element is not an attribute then at 860 ageneric method call can be generated such as Dot(“Y”). An originalexpression of X.Y, can, in this instance, be transformed to X.Dot(“Y”).

It should be appreciated that methodology 800 is merely exemplary. Asimilar methodology can be employed for other particular elementsincluding but not limited to selection of descendants. For example, adelimiter that includes three dots ( . . . ) can indicate that adescendant method call should be selected for the translated expression.

As mentioned previously, the subject invention contemplates employmentwith respect to XML. The following code sample shows how a portion ofmethodology 800 can be implemented, for instance in a compiler inaccordance with an aspect of the subject invention. In the subjectexample, a method VisitQualifiedIdentifier returns the expression thatrepresents the member (QualifiedIdentifier) of a specific class. If theexpression is null, meaning the member was not found, then the followingmethod GetDynamicProperty can be called.

private Expression GetDynamicProperty(QualifiedIdentifierqualifiedIdentifier){  //Get the qualifier type  TypeNode t =qualifiedIdentifier.Qualifier.Type;  //Get the QualifiedIdentifier name string propName = qualifiedIdentifier.Identifier.SourceContext.SourceText;  //Choose themethod based on whether the name starts with “@”  Identifier methodName= propName.StartsWith(“@”) ? new Identifier(“DotAttribute”) : newIdentifier(“Dot”);  TypeNode[ ] args = new TypeNode[]{SystemTypes.String};  if (t != null && t.GetMethod(methodName, args)!= null)  //Get the method from the type   Method m =t.GetMethod(methodName, args);   MemberBinding dynamicBinding = newMemberBinding(qualifier, m);  //Replace the qualified identifier with amethod call and return it   MethodCall mc = newMethodCall(dynamicBinding, new   ExpressionList( ), Nodetype.MethodCall,m.ReturnType);   mc.Operands.Add(new Literal(propName,SystemTypes.String));  if(ns != null) mc.Operands.Add(new Literal(ns,SystemTypes.String));   return mc;  else   return null; }Here, the programmatic expression is referred to as a qualifiedidentifier. In the first portion of the code, the type of the qualifiedexpression is received. In the case of XML, this could be anXPathIterator type. The qualifiedtype property name is received. Forexample, in a qualified identifier expression such as books.price, theprice would be the property name. In another code section, a method ischosen based on whether the name property name starts with or adelimiter includes a “@,” namely either DotAttribute or Dot. The methodalso determines the arguments for the particular method; In the aboveexample, the argument would simply be price. The type of the firstmember is subsequently bound to the chosen method. In the subjectexample, this could correspond to binding book, or more specifically thetype thereof, to a dot method call. Finally, the chosen method and thearguments are appended together to generate a translated expression orqualified identifier such as books. Dot(“price”).

Furthermore, it should be noted that in XML there is a notion ofnamespaces, for example <xmlns: x=“http:// . . . ”>. What this means isthat all names are prefixed with a specified namespace. For example, auser could specify a namespace in a qualified identifier or programmaticexpression such as book.x:price. The systems and methods of the subjectinvention can see that colon and determine that they need to lookup thenamespace. When a generic method call is generated the namespace can beprovided as the second argument, for example books.Dot(“price”, http://. . . ).

FIG. 9 is a flow chart diagram depicting a compilation methodology 900in accordance with an aspect of the subject invention. At 910, a genericmethod call is identified, such as Dot( ) or DotAttribute( ). At 920, atype method implementation is located, for example for an expressionX.Dot(“Y”). The type of X associated with the generic method callDot(“Y”) can be located in the type class of X. At 930, the genericmethod call is bound to the located or identified type methodimplementation. Accordingly, execution of the generic method call willproduces results specific to the type.

The following sections provide examples of how generic method calls suchas Dot can be implemented using the System.Xml.XPath classes, namelyXPathDocument, XPathNavigator, and XPathNodeIterator.

The first class created is XPathNavigatorCollection as provided hereinas Appendix A. This class is the return type for every “Dot” method. Itreturns a collection of DynamicXPathNavigator, which is a wrapper aroundXPathNavigator. Each navigator points to a specific Xml node. It shouldbe noted that the DotAttribute is not implemented in this class since anXml attribute cannot have child nodes.

The next class is the DynamicXPathDocument class, which is a wrapper forthe XPathDocument class. This class is initialized by passing the URL(Uniform Resource Location) for the XML document similar to theXPathDoucment class. Furthermore, the Dot and DotAttribute methods areimplemented herein. For example:

public class DynamicXPathDocument {  private XPathDocument doc;  publicDynamicXPathDocument(string documentURI) {   doc = newXPathDocument(documentURI);  }  public XPathNavigatorCollectionDot(string propName){   return new  XPathNavigatorCollection(doc.CreateNavigator( ).Select(propName));  } public XPathNavigatorCollection DotAttribute(string propName){   returnnew   XPathNavigatorCollection(doc.CreateNavigator( ).Select(propName)); } }

Finally, the last class is DynamicXPathNavigator. This class is awrapper for the XPathNavigator class, which points to a specific XMLnode.

public class DynamicXPathNavigator {  public XPathNavigator nav;  publicDynamicXPathNavigator(XPathNavigator navigator) {   nav = navigator;  } public XPathNavigatorCollection Dot(string propName) {   return newXPathNavigatorCollection(this, propName);  }  publicXPathNavigatorCollection DotAttribute(string propName) {   return newXPathNavigatorCollection(this, propName);  }  public static implicitoperator string(DynamicXPathNavigator navigator){   returnnavigator.nav.Value;  } }

These three classes in combination with specialized compiler support foroverloading member access on these types provide a way to overload the“.” operator in an XML API and translate the member selection into asearch for the applicable XML node that matches the identifier name.This provides a much more natural and straightforward means andmechanism to read and maintain code.

FIG. 10 is a block diagram depicting a compiler environment 1000 thatcan be utilized to produce implementation code. The compiler environment1000 includes a compiler 1010 including front-end component 1020,converter component 1030, back-end component 1040, error checkercomponent 1050, symbol table 1060, parse tree 1070, and state 1080. Thecompiler 1010 accepts source code as input and produces implementationcode as output. The input can include but is not limited to delimitedprogrammatic expressions or qualified identifier as described herein.The relationships amongst the components and modules of the compilerenvironment illustrated the main flow of data. Other components andrelationships are not illustrated for the sake of clarity andsimplicity. Depending on implementation, components can be added,omitted, split into multiple modules, combined with other modules,and/or other configurations of modules.

Compiler 1010 can accept as input a file having source code associatedwith processing of a sequence of elements. The source code may includecode defining a collection of elements and methods for traversing suchelements. Compiler 1010 may process source code in conjunction with oneor more components for analyzing constructs and generating or injectingcode.

A front-end component 1020 reads and performs lexical analysis upon thesource code. In essence, the front-end component 1020 reads andtranslates a sequence of characters (e.g., alphanumeric) in the sourcecode into syntactic elements or tokens, indicating constants,identifiers, operator symbols, keywords, and punctuation among otherthings.

Converter component 1030 parses the tokens into an intermediaterepresentation. For instance, the converter component 1030 can checksyntax and group tokens into expressions or other syntactic structures,which in turn coalesce into statement trees. Conceptually, these treesform a parse tree 1070. Furthermore and as appropriate, the convertermodule 1030 can place entries into a symbol table 1030 that lists symbolnames and type information used in the source code along with relatedcharacteristics.

A state 1080 can be employed to track the progress of the compiler 1010in processing the received or retrieved source code and forming theparse tree 1070. For example, different state values indicate that thecompiler 1010 is at the start of a class definition or functions, hasjust declared a class member, or has completed an expression. As thecompiler progresses, it continually updates the state 1480. The compiler1010 may partially or fully expose the state 1080 to an outside entity,which can then provide input to the compiler 1010.

Based upon constructs or other signals in the source code (or if theopportunity is otherwise recognized), the converter component 1030 oranother component can inject code corresponding to dot methods, amongother things. Rules coded into the converter component 1030 or othercomponent indicates what must be done to implement the desiredfunctionality and identify locations where the code is to be injected orwhere other operations are to be carried out. Injected code typicallyincludes added statements, metadata, or other elements at one or morelocations, but this term can also include changing, deleting, orotherwise modifying existing source code. Injected code can be stored asone or more templates or in some other form. In addition, it should beappreciated that symbol table manipulations and parse treetransformations can take place.

Based on the symbol table 1060 and the parse tree 1070, a back-endcomponent 1040 can translate the intermediate representation into outputcode. The back-end component 1040 converts the intermediaterepresentation into instructions executable in or by a target processor,into memory allocations for variables, and so forth. The output code canbe executable by a real processor, but the invention also contemplatesoutput code that is executable by a virtual processor.

Furthermore, the front-end component 1020 and the back end component1040 can perform additional functions, such as code optimization, andcan perform the described operations as a single phase or in multiplephases. Various other aspects of the components of compiler 1010 areconventional in nature and can be substituted with components performingequivalent functions. Additionally, at various during processing of thesource code, an error checker component 1050 can check for errors suchas errors in lexical structure, syntax errors, and even semantic errors.Upon detection error, checker component can halt compilation andgenerate a message indicative of the error.

In order to provide a context for the various aspects of the invention,FIGS. 11 and 12 as well as the following discussion are intended toprovide a brief, general description of a suitable computing environmentin which the various aspects of the present invention may beimplemented. While the invention has been described above in the generalcontext of computer-executable instructions of a computer program thatruns on a computer and/or computers, those skilled in the art willrecognize that the invention also may be implemented in combination withother program modules. Generally, program modules include routines,programs, components, data structures, etc. that perform particulartasks and/or implement particular abstract data types. Moreover, thoseskilled in the art will appreciate that the inventive methods may bepracticed with other computer system configurations, includingsingle-processor or multiprocessor computer systems, mini-computingdevices, mainframe computers, as well as personal computers, hand-heldcomputing devices, microprocessor-based or programmable consumerelectronics, and the like. The illustrated aspects of the invention mayalso be practiced in distributed computing environments where task areperformed by remote processing devices that are linked through acommunications network. However, some, if not all aspects of theinvention can be practiced on stand-alone computers. In a distributedcomputing environment, program modules may be located in both local andremote memory storage devices.

With reference to FIG. 11, an exemplary environment 1100 forimplementing various aspects of the invention includes a computer 1112.The computer 1112 includes a processing unit 1114, a system memory 1116,and a system bus 1118. The system bus 1118 couples system componentsincluding, but not limited to, the system memory 1116 to the processingunit 1114. The processing unit 1114 can be any of various availableprocessors. Dual microprocessors and other multiprocessor architecturesalso can be employed as the processing unit 1114.

The system bus 1118 can be any of several types of bus structure(s)including the memory bus or memory controller, a peripheral bus orexternal bus, and/or a local bus using any variety of available busarchitectures including, but not limited to, 11-bit bus, IndustrialStandard Architecture (ISA), Micro-Channel Architecture (MSA), ExtendedISA (EISA), Intelligent Drive Electronics (IDE), VESA Local Bus (VLB),Peripheral Component Interconnect (PCI), Universal Serial Bus (USB),Advanced Graphics Port (AGP), Personal Computer Memory CardInternational Association bus (PCMCIA), and Small Computer SystemsInterface (SCSI).

The system memory 1116 includes volatile memory 1120 and nonvolatilememory 1122. The basic input/output system (BIOS), containing the basicroutines to transfer information between elements within the computer1112, such as during start-up, is stored in nonvolatile memory 1122. Byway of illustration, and not limitation, nonvolatile memory 1122 caninclude read only memory (ROM), programmable ROM (PROM), electricallyprogrammable ROM (EPROM), electrically erasable ROM (EEPROM), or flashmemory. Volatile memory 1120 includes random access memory (RAM), whichacts as external cache memory. By way of illustration and notlimitation, RAM is available in many forms such as synchronous RAM(SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rateSDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), Synchlink DRAM (SLDRAM), anddirect Rambus RAM (DRRAM).

Computer 1112 also includes removable/non-removable,volatile/non-volatile computer storage media. FIG. 11 illustrates, forexample disk storage 1124. Disk storage 4124 includes, but is notlimited to, devices like a magnetic disk drive, floppy disk drive, tapedrive, Jaz drive, Zip drive, LS-100 drive, flash memory card, or memorystick. In addition, disk storage 1124 can include storage mediaseparately or in combination with other storage media including, but notlimited to, an optical disk drive such as a compact disk ROM device(CD-ROM), CD recordable drive (CD-R Drive), CD rewritable drive (CD-RWDrive) or a digital versatile disk ROM drive (DVD-ROM). To facilitateconnection of the disk storage devices 1124 to the system bus 1118, aremovable or non-removable interface is typically used such as interface1126.

It is to be appreciated that FIG. 11 describes software that acts as anintermediary between users and the basic computer resources described insuitable operating environment 1110. Such software includes an operatingsystem 1128. Operating system 1128, which can be stored on disk storage1124, acts to control and allocate resources of the computer system1112. System applications 1130 take advantage of the management ofresources by operating system 1128 through program modules 1132 andprogram data 1134 stored either in system memory 1116 or on disk storage1124. It is to be appreciated that the present invention can beimplemented with various operating systems or combinations of operatingsystems.

A user enters commands or information into the computer 1112 throughinput device(s) 1136. Input devices 1136 include, but are not limitedto, a pointing device such as a mouse, trackball, stylus, touch pad,keyboard, microphone, joystick, game pad, satellite dish, scanner, TVtuner card, digital camera, digital video camera, web camera, and thelike. These and other input devices connect to the processing unit 1114through the system bus 1118 via interface port(s) 1138. Interfaceport(s) 1138 include, for example, a serial port, a parallel port, agame port, and a universal serial bus (USB). Output device(s) 1140 usesome of the same type of ports as input device(s) 1136. Thus, forexample, a USB port may be used to provide input to computer 1112 and tooutput information from computer 1112 to an output device 1140. Outputadapter 1142 is provided to illustrate that there are some outputdevices 1140 like displays (e.g., flat panel and CRT), speakers, andprinters, among other output devices 1140 that require special adapters.The output adapters 1142 include, by way of illustration and notlimitation, video and sound cards that provide a means of connectionbetween the output device 1140 and the system bus 1118. It should benoted that other devices and/or systems of devices provide both inputand output capabilities such as remote computer(s) 1144.

Computer 1112 can operate in a networked environment using logicalconnections to one or more remote computers, such as remote computer(s)1144. The remote computer(s) 1144 can be a personal computer, a server,a router, a network PC, a workstation, a microprocessor based appliance,a peer device or other common network node and the like, and typicallyincludes many or all of the elements described relative to computer1112. For purposes of brevity, only a memory storage device 1146 isillustrated with remote computer(s) 1144. Remote computer(s) 1144 islogically connected to computer 1112 through a network interface 1148and then physically connected via communication connection 1150. Networkinterface 1148 encompasses communication networks such as local-areanetworks (LAN) and wide-area networks (WAN). LAN technologies includeFiber Distributed Data Interface (FDDI), Copper Distributed DataInterface (CDDI), Ethernet/IEEE 802.3, Token Ring/IEEE 802.5 and thelike. WAN technologies include, but are not limited to, point-to-pointlinks, circuit-switching networks like Integrated Services DigitalNetworks (ISDN) and variations thereon, packet switching networks, andDigital Subscriber Lines (DSL).

Communication connection(s) 1150 refers to the hardware/softwareemployed to connect the network interface 1148 to the bus 1118. Whilecommunication connection 1150 is shown for illustrative clarity insidecomputer 1112, it can also be external to computer 1112. Thehardware/software necessary for connection to the network interface 1148includes, for exemplary purposes only, internal and externaltechnologies such as, modems including regular telephone grade modems,cable modems, power modems and DSL modems, ISDN adapters, and Ethernetcards.

FIG. 12 is a schematic block diagram of a sample-computing environment1200 with which the present invention can interact. The system 1200includes one or more client(s) 1210. The client(s) 1210 can be hardwareand/or software (e.g., threads, processes, computing devices). Thesystem 1200 also includes one or more server(s) 1230. The server(s) 1230can also be hardware and/or software (e.g., threads, processes,computing devices). The server(s) 1230 can house threads to performtransformations by employing the present invention, for example.

One possible communication between a client 1210 and a server 1230 maybe in the form of a data packet transmitted between two or more computerprocesses. The system 1200 includes a communication framework 1250 thatcan be employed to facilitate communications between the client(s) 1210and the server(s) 1230. The client(s) 1210 are operatively connected toone or more client data store(s) 1260 that can be employed to storeinformation local to the client(s) 1210. Similarly, the server(s) 1230are operatively connected to one or more server data store(s) 1240 thatcan be employed to store information local to the servers 1230.

What has been described above includes examples of the presentinvention. It is, of course, not possible to describe every conceivablecombination of components or methodologies for purposes of describingthe present invention, but one of ordinary skill in the art mayrecognize that many further combinations and permutations of the presentinvention are possible. Accordingly, the present invention is intendedto embrace all such alterations, modifications and variations that fallwithin the spirit and scope of the appended claims. Furthermore, to theextent that the terms “includes,” “has,” and “having” are used in eitherthe detailed description or the claims, such term is intended to beinclusive in a manner similar to the term “comprising” as “comprising”is interpreted when employed as a transitional word in a claim.

APPENDIX A public XPathNavigatorCollection(XPathNavigatorCollectioniterator, string propName) {   //for each navigator get all the childrenthat match the property name   foreach(navigator in iterator)   Select(navigator, propName);   e = navigators.GetEnumerator( );  } public XPathNavigatorCollection(DynamicXPathNavigator navigator, stringpropName){   //for a certain navigator get all the children that matchethe property name   Select(navigator, propName);   e =navigators.GetEnumerator( );  }  private voidSelect(DynamicXPathNavigator navigator, string propName) { //Using theXML API the property name is translated into calls to the appropriatemethods in the XPathNavigator class   nav = navigator.nav;  XPathNodeIterator itr;   if(propName.StartsWith(“@”)) {    propName =propName.TrimStart(‘@’);    newNav = nav.Clone( );   newNav.MoveToAttribute(propName, “ ”);    navigators.Add(newDynamicXPathNavigator(newNav));   }   else {    itr =nav.SelectChildren(propName, “ ”);    while(itr.MoveNext( )) {    navigators.Add(new DynamicXPathNavigator(itr.Current.Clone( )));   }   }  }  public XPathNavigatorCollection(XPathNodeIterator iterator){   while(iterator.MoveNext( )) {    navigators.Add(newDynamicXPathNavigator(iterator.Current.Clone( )));   }   e =navigators.GetEnumerator( );  } //Implementation of the Dot methodssimply returns a new collection of child node for every navigator in thecollection.  public XPathNavigatorCollection Dot(string propName){  return new XPathNavigatorCollection(this, propName);  }  publicIEnumerator<DynamicXPathNavigator> GetEnumerator( ) {   return e;  } public void Dispose( ) {   e = null;  }  public bool MoveNext( ) {  return e.MoveNext( );  }  public DynamicXPathNavigator Current {  get{ return e.Current; }  } //Implicit casting to string provides away to get the Value of the current node in the collection as string public static implicit operator string(XPathNavigatorCollection col){  enumerator = col.GetEnumerator( );   if(enumerator==null ||!enumerator.MoveNext( )) return null;   returnenumerator.Current.nav.Value;  }  public DynamicXPathNavigator this[intidx] {   get{ return navigators[idx]; }  } }

1. A compilation system comprising: a processor: a memorycommunicatively coupled to the processor, the memory having storedtherein computer-executable instructions configured to implement thecompilation system including: a receiver component that receives adelimited programmatic expression comprising a first element, adelimiter, and a second element wherein the programmatic expression is amember access expression where the first element is a receiverexpression, the second element is a message identifier, and thedelimiter is one of a dot (.), a series of dots ( . . . ), anexclamation point (!), or a pound symbol (#); a type detection componentthat determines the type of the first element; and a generationcomponent that produces a translated expression based on the type of thefirst element and identities of the first element, the delimiter and thesecond element, wherein producing the translated expression comprises:determining whether the second element represents or is a member of thetype of the first element; and generating a different type of translatedexpression based on whether the second element represents or is a memberof the type of the first element, namely:  when the second elementrepresents or is a member of the type of the first element, generating atranslated expression that incorporates standard methods for thedelimiter; and  when the second element does not represent and is not amember of the type of the first element, generating a generic methodcall as the translated expression, the generic method call notspecifying any particular translation and not being bound to anyparticular method type.
 2. The system of claim 1, the translatedexpression includes a method call to a source code that provides accessto or interaction with one or more objects.
 3. The system of claim 2,the source code is XML to access one or more XML objects.
 4. The systemof claim 3, specific delimiters map to particular XPath axis objects. 5.The system of claim 1, the message identifier is mapped to selectattributes when the message identifier is in the form @name andname-space access when the message identifier is in the formprefix:name.
 6. The system of claim 1, further comprising an ambiguityresolution component that determines whether special or normal memberaccess code will be produced, when the message identifier is a directmember of the detected type.
 7. The system of claim 6, the ambiguityresolution component determination is influenced by the expressiondelimiter such that either ambiguity component defaults to normal memberaccess and is overridden by a particular delimiter to produce specialmember access code or defaults to special member access code which maybe overridden by the presence of a particular delimiter to producenormal member access code.
 8. The system of claim 1, further comprisinga binding component that that binds the expression produced by thegeneration component to the type determined by the type detectioncomponent.
 9. A compilation system comprising: a processor; a memorycommunicatively coupled to the processor, the memory having storedtherein computer-executable instructions configured to implement thecompilation system including: means for receiving a delimitedprogrammatic expression comprising; a first element; a second element;and a delimiter, separating the first element from the second element,and wherein the delimiter is one of; a dot (.); a series of dots ( . . .); an exclamation point (!); or a pound symbol (#); means for generatinga method call based on the received expression and in accordance with ameta-object protocol, wherein a type of the method call is generateddifferently based on whether the second element is related to or is amember of the type of the first element and includes: determiningwhether the second element represents or is a member of the type of thefirst element; generating a different type of translated expressionbased on whether the second element represents or is a member of thetype of the first element, namely: when the second element represents oris a member of the type of the first element, generated a translatedexpression that incorporates standard methods for the delimiter; andwhen the second element does not represent and is not a member of thetype of the first element, generating a generic method call as thetranslated expression, the generic call not specifying any particulartranslation and not being bound to any particular method type; and meansfor incorporating the method call into the received expression togenerate a translated expression.
 10. The system of claim 9, furthercomprising a means for binding the method call to a type specificimplementation that generates valid XML code to access one or more XMLobjects.
 11. A programmatic expression compilation method comprising:using a processor of a computing system: receiving a programmaticexpression that includes a first element, a delimiter, and a secondelement, wherein the delimiter immediately follows the first element andthe second element immediately follows the delimiter, and wherein thedelimiter is one of a dot (.), a series of dots ( . . . ), anexclamation point (!), or a pound symbol (#); determining the type ofthe first element; and generating a translated expression based on thedetermined type of the first element and the identities of the firstelement, delimiter, and second element, wherein generating thetranslated expression comprises: determining whether the second elementis a property or field of the type of the first element; and generatinga different type of translated expression based on whether the secondelement is a property or field of the type of the first element, namely:when the second element is a property or field of the type of the firstelement, generating a translated expression that incorporates standardmethods for the delimiter; and when the second element is not a propertyor field of the type of the first element, generating a generic methodcall as the translated expression, the generic method call notspecifying any particular translation and not being bound to anyparticular method type.
 12. The method of claim 11, further comprisingafter generating the generic method call, binding the generic methodcall to a type, the type of the first element.
 13. The method of claim12, further comprising accessing objects by executing type specific codebound to the generic method call.
 14. The method of claim 11, generatinga translated expression comprising generating a standard access orupdate method provided by the object type to retrieve data specified bythe second element, if the second element is a member of the firstelement type.
 15. The method of claim 11, receiving a programmaticexpression comprises receiving an expression for navigating XMLdocuments.
 16. The method of claim 12, wherein receiving theprogrammatic expression and generating the translated expression occurprior to compiling, and wherein binding the generic method call to atype is performed during compiling.
 17. The method of claim 16, whereinthe received programmatic expression is an XML document, and whereingenerating the generic method call provides object-oriented access tothe XML document.